home *** CD-ROM | disk | FTP | other *** search
/ Clickx 31 / Clickx 31.iso / assets / software / MyServer-win32-0.8.2.exe / web / documentation / texts / security.htm < prev    next >
Encoding:
Extensible Markup Language  |  2005-09-29  |  5.2 KB  |  103 lines

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
  3.   "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
  4. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
  5. <head>
  6. <title>MyServer Documentation - Controling Access - www.myserverproject.net</title>
  7. <meta http-equiv="content-type" content="text/html;charset=UTF-8" />
  8. <meta http-equiv="Content-Style-Type" content="text/css" />
  9. <link rel="stylesheet" type="text/css" href="../style/myserver.css" />
  10. </head>
  11. <body>
  12. <table class="center" width="95%">
  13. <tr>
  14. <td class="center">
  15. <h1 class="title">CONTROLLING ACCESSES</h1>
  16.       <br />
  17.         In order to control the access to a file, you must add the security in 
  18.         the directory you would like to protect.<br />
  19.         <br />
  20.         The syntax of the file is:<br />
  21.         <br />
  22.         <span class="code"> <?xml version="1.0"?><br />
  23.         <SECURITY><br />
  24.         <HTTP TRACE="ON" /><br />
  25.         <AUTH TYPE="Basic" /></span><span class="code"><br />
  26.         <ACTION name="Host" value="localhost">ALLOW</ACTION><br />
  27.         <USER NAME="God" PASS="godpassword" READ="TRUE" WRITE="TRUE" BROWSE="TRUE" 
  28.         EXECUTE="TRUE" /><br />
  29.         <!--This is the setting for the user--><br />
  30.         <USER NAME="Guest" PASS="" READ="TRUE" BROWSE="TRUE"/><br />
  31.         <!--The guest user--><br />
  32.         <USER NAME="Tim" PASS="Tom" READ="TRUE" EXECUTE="TRUE" BROWSE="TRUE"/><br />
  33.         <!--Another user--><br />
  34.         <ITEM FILE="file1" READ="TRUE" WRITE="FALSE" EXECUTE="FALSE"><br />
  35.         <ACTION name="Host" value="remote">DENY</ACTION><br />
  36.         <!--Define a file and its permissions--><br />
  37.         <USER NAME="Jim" PASS="Morrison" READ="TRUE" WRITE="FALSE" EXECUTE="FALSE" 
  38.         /><br />
  39.         <!--Define the user permissions for the file--><br />
  40.         <USER NAME="Bob" PASS="Marley" READ="TRUE" WRITE="FALSE" EXECUTE="TRUE" 
  41.         /><br />
  42.         <ACTION name="Host" value="localhost">DENY</ACTION> 
  43.         <br />
  44.         <!--Another user permissions for the file--><br />
  45.         </ITEM><br />
  46.         <--End of the file block--><br />
  47.         </SECURITY><br />
  48.         </span> <br />
  49.         <br />
  50.         The line <span class="code"><HTTP TRACE="ON" /></span> is optional, 
  51.         and is described in the <a href="virtualhosts.htm">Virtual Hosts</a> section 
  52.         of this guide. Please, go to that link if you want to understand about 
  53.         that line.<br />
  54.         <br />
  55.         The line <span class="code"><AUTH TYPE="Basic" /></span>, optional, 
  56.         selects the authentication scheme to be used for your site. Its default 
  57.         value is "Basic", but you can also use "Digest", so it will look like 
  58.         this:<br />
  59.         <br />
  60.         <span class="code"><AUTH TYPE="Digest" /></span><br />
  61.         if the line isn't in the file, the default "Basic" will be used.<br />
  62.         The "Digest" schema is safer, as the passwords aren't transferred open 
  63.         through the net.<br />
  64.         <br />
  65.         The engine first checks to see if the user has permissions in the file 
  66.         block:<br />
  67.         <span class="code"><USER NAME="Bob" PASS="Marley" READ="TRUE" WRITE="FALSE" 
  68.         EXECUTE="TRUE" /></span><br />
  69.         <br />
  70.         If there are no permissions defined, the engine tries to use the permissions 
  71.         that are defined for the file:<br />
  72.         <span class="code"><ITEM FILE="file1" READ="TRUE" WRITE="FALSE" EXECUTE="FALSE"></span><br />
  73.         <br />
  74.         If the engine cannot find any file permissions, it then uses the general 
  75.         settings for the user: <br />
  76.         <br />
  77.         <span class="code"><USER NAME="Guest" PASS="" READ="TRUE" BROWSE="TRUE"/></span><br />
  78.         <br />
  79.         If the user is not defined, the engine will send an error to the user.<br />
  80.         <br />
  81.         <br />
  82.         <br />
  83.         <span class="code">The <ACTION></span> lines above define if a resource 
  84.         will be allowed to be accessed or not, depending on the conditions. For 
  85.         example, the line <br />
  86.       <br /><br /><span class="code"><ACTION name="Host" value="remote">DENY</ACTION></span>
  87.       <br /><br />means the file "file1" will be denied if the Host used to access 
  88.         the file is "remote" as hostname. But if there were others maps 
  89.         to the file in other hostnames, for example "localhost", it 
  90.         can be accessed, execpt by user Bob, as specified by the line below:<br />
  91.         <br />
  92.       <span class="code"><ACTION name="Host" value="localhost">DENY</ACTION> 
  93.       </span> <br />
  94.       <br /><br />
  95.       
  96.         If the security file is not present, a default security file will be used 
  97.         by the engine. The default security file is found in the system directory.<br />
  98.       
  99.       </td>
  100. </tr>
  101. </table>
  102. </body>
  103. </html>